<template>
  <div id="app">
    <Header style="position:absolute;top:0;width:100%" v-if="isShow"></Header>
    <router-view/>
    <Footer  v-if="isShow"></Footer>
  </div>
</template>
<script>
import Header from './components/common/header.vue'
import Footer from './components/common/footer.vue'
export default {
  data(){
    return {
      isShow:false,
    }
  },
  components:{
    Header,
    Footer
  },
  watch:{
    $route(){
    　let path = this.$route.path
      if(path.indexOf('studyCenter')!=-1||path.indexOf('member')!=-1){
        this.isShow = true
      }else{
        this.isShow = false
      }
    }
  },
  mounted(){
    let path = this.$route.path
    if(path.indexOf('studyCenter')!=-1||path.indexOf('member')!=-1){
      this.isShow = true
    }else{
      this.isShow = false
    }
  }
}
</script>

<style>
.iconfont {
    font-family: "iconfont" !important;
    font-size: 6rem;
    font-style: normal;
    -webkit-font-smoothing: antialiased;
    -webkit-text-stroke-width: 0.2px;
    -moz-osx-font-smoothing: grayscale;
}
</style>
